//所有的配置文件
import path from "path";
const DB_URL = 'mongodb://localhost:27017/koa-api'
const REDIS = {
  host: '127.0.0.1',
  port: '15001',
  password: '123456'
}
const JWT_SECRET = 'walker-7d3ab835-0bc0-42b3-b152-1b3aaee7f77f'

const baseUrl = process.env.NODE_ENV === 'production' ? 'http://www.baidu.com' : 'http://localhost:8080'

const uploadPath = process.env.NODE_ENV === 'production' ? '/app/public' : path.join(path.resolve(__dirname), '../../public')
export default {
  DB_URL,
  REDIS,
  JWT_SECRET,
  baseUrl,
  uploadPath
}
